package com.ele.Dao;

import com.ele.Pojo.Food;

import java.sql.SQLException;
import java.util.List;

public interface FoodDao {
    /**
     * 分页和条件查询菜品
     * @param currentPage
     * @param pageSize
     * @param categoryId
     * @param shopId
     * @return
     */
    List<Food> findFoodList(String currentPage, String pageSize, String categoryId, String shopId , String foodName) throws SQLException;

    /**
     * 查询某个店铺的菜品数据个数
     * @param shopId
     * @return
     */
    Long foodCount(String shopId) throws SQLException;

    /**
     * 添加菜品
     * @param food
     * @return
     * @throws SQLException
     */
    Integer addFood(Food food)throws SQLException;

    /**
     * 根据菜品id修改
     * @param food
     * @return
     * @throws SQLException
     */
    Integer updateFood(Food food)throws SQLException;

    /**
     * 根据菜品id删除
     * @param foodId
     * @return
     */
    Integer deleteFood(String foodId)throws SQLException;
}
